home *** CD-ROM | disk | FTP | other *** search
/ Magnum One / Magnum One (Mid-American Digital) (Disc Manufacturing).iso / d16 / wc15_b.arc / VT102.WMS < prev    next >
Text File  |  1991-03-22  |  2KB  |  62 lines

  1. ;Playback of VT102 files demo
  2.  
  3. STOP                              ;stops the session if it is started                  
  4. USERWINDOW(5,0,0,12632256)
  5. METABKG(0,0,1,"synapp.wmf")       ;displays the SYNAPPSYS logo
  6. show(6)
  7. lenth = 2
  8. GOSUB pause
  9. DIALOGBOX 50,50,229,60,21,"VT 102 Demonstration"
  10.         LTEXT 8,8,224,37,"This part of the demonstration will replay a file that contains VT102 escape sequences.  The file is VT102.EMU."
  11.         DEFCANCELBUTTON 90,42,50,15,"&OK"
  12. DEND
  13. dtime = 10
  14. gosub delay
  15.  
  16. CLEAR
  17. DELOBJECT(0,0,0)              ;clears the graphic
  18. show(8)
  19. open("VT102.WSF","",1)        ;opens the session file setup with VT102 terminal type selected
  20. lenth = 2
  21. key1 = 0
  22. key = 38
  23.  
  24.  
  25. lenth = 1
  26. sendspeckey(1,0,asc("F"))     ; 1 == alt key, selects the FILE menu
  27. gosub pause
  28. sendspeckey(0,0,asc("Y"))     ; selects the Playback menu item
  29. gosub pause
  30. sendspeckey(0,0,asc("V"))     ; types VT102.EMU in the edit box
  31. sendspeckey(0,0,asc("T"))
  32. sendspeckey(0,0,asc("1"))
  33. sendspeckey(0,0,asc("0"))
  34. sendspeckey(0,0,asc("2"))
  35. sendspeckey(0,0,110)
  36. sendspeckey(0,0,asc("E"))
  37. sendspeckey(0,0,asc("M"))
  38. sendspeckey(0,0,asc("U"))
  39. gosub pause
  40. sendspeckey(0,0,13)           ; send carrage return
  41. HALT
  42.  
  43. pause:
  44. i = time?+lenth
  45. while(time? <i)
  46. wend
  47. return
  48.  
  49.  
  50. delay:                          ;automatically destroys the dialog box by 
  51. i = time?+dtime                 ;sending a carrage return after a timeout
  52. j = 255                         ;if the CONTINUE button is not selected beforehand
  53. while((time?<i) && (j == 255))
  54. j = DIALOG?
  55. wend
  56. if(j == 255)
  57.   sendspeckey(0,0,13)
  58. return
  59.  
  60. end
  61.  
  62.